[GENERAL] Emptying a database. - Mailing list pgsql-general

From Stuart Rison
Subject [GENERAL] Emptying a database.
Date
Msg-id l03110721b242835641f1@[128.40.242.190]
Whole thread Raw
Responses Re: [GENERAL] Emptying a database.
List pgsql-general
Dear All,

I'm currently doing some database design work and find myself entering
loads of test records into my database tables.

Occasionally I want to 'flush' out the database (i.e. keep all tables,
views, etc. but delete all records).  Currently I have to pg_dump the
database and then use a text editor to cut out all the 'copy' statements
out and recreate a 'new' database.

Is there a way of flushing the content of all tables?

Thanks for any help you may provide.

Cheers,

Stuart.


+-------------------------+--------------------------------------+
| Stuart Rison            | Ludwig Institute for Cancer Research |
+-------------------------+ 91 Riding House Street               |
| Tel. (0171) 878 4041    | London, W1P 8BT, UNITED KINGDOM.     |
| Fax. (0171) 878 4040    | stuart@ludwig.ucl.ac.uk              |
+-------------------------+--------------------------------------+



pgsql-general by date:

Previous
From: Memphisto
Date:
Subject: My further experiences with ecpg
Next
From: Jeremiah Davis
Date:
Subject: Re: [GENERAL] Emptying a database.